﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="ExpensesManager.aspx.cs"
    Inherits="BalanceInfo_ExpensesManager" CodeFileBaseClass="Frame.Pages.ActionInfomationEditBasePage"
    MasterPageFile="~/MainMaster.master" %>

<%@ Register Assembly="DevExpress.Web.v10.2, Version=10.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxRoundPanel" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.v10.2.Linq, Version=10.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Data.Linq" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.ASPxGridView.v10.2, Version=10.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxGridView" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.ASPxEditors.v10.2, Version=10.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxEditors" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.v10.2, Version=10.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxPanel" TagPrefix="dx" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
    <link href="Css/web20110913.css" rel="stylesheet" type="text/css" charset="gb2312" />
    <script type="text/javascript" src="../Scripts/ToChineseSpell.js"></script>
    <script type="text/javascript" src="../Scripts/EnterAsTab.js"></script>
</asp:Content>
<asp:Content ID="Content2" runat="server" ContentPlaceHolderID="MainContent">
    <h1 class="DemoTitle">
        费用管理
    </h1>
    <div id="DemoArea">
        <div class="Spacer" style="height: 14px;">
        </div>
        <div style="display: none">
            <dx:ASPxTextBox ID="fy" runat="server" Width="170px" ClientInstanceName="fy">
            </dx:ASPxTextBox>
        </div>
        <dx:ASPxRoundPanel ID="MainRoundPanel" runat="server" View="GroupBox" Width="100%"
            CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" CssPostfix="Office2010Blue"
            EnableDefaultAppearance="False" GroupBoxCaptionOffsetX="6px" GroupBoxCaptionOffsetY="-19px"
            SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css">
            <ContentPaddings PaddingBottom="10px" PaddingLeft="9px" PaddingRight="11px" PaddingTop="10px" />
            <HeaderStyle>
                <Paddings PaddingBottom="6px" PaddingLeft="9px" PaddingRight="11px" PaddingTop="3px" />
            </HeaderStyle>
            <PanelCollection>
                <dx:PanelContent runat="server" SupportsDisabledAttribute="True">
                </dx:PanelContent>
            </PanelCollection>
        </dx:ASPxRoundPanel>
        <dx:ASPxGridView ID="gridView" runat="server" AutoGenerateColumns="False" CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css"
            CssPostfix="Office2010Blue" DataSourceID="LSMDSourceMain" EnableCallBacks="False"
            KeyFieldName="fybm" Width="100%" OnCellEditorInitialize="gridView_CellEditorInitialize">
            <SettingsEditing EditFormColumnCount="2" Mode="PopupEditForm" PopupEditFormModal="true"
                PopupEditFormHorizontalAlign="WindowCenter" PopupEditFormVerticalAlign="WindowCenter" />
            <Columns>
                <dx:GridViewDataTextColumn FieldName="fybm" Caption="费用编码" Name="t_fybm" ReadOnly="True"
                    VisibleIndex="0">
                    <PropertiesTextEdit Native="true" Width="200px" MaxLength="10" Style-Font-Size="10pt">
                        <ValidationSettings CausesValidation="true">
                        </ValidationSettings>
                        <Style Font-Size="10pt"></Style>
                    </PropertiesTextEdit>
                    <EditFormSettings CaptionLocation="Near" />
                    <EditFormSettings CaptionLocation="Near"></EditFormSettings>
                    <CellStyle HorizontalAlign="Center">
                    </CellStyle>
                </dx:GridViewDataTextColumn>
                <dx:GridViewDataTextColumn FieldName="fymc" Caption="费用名称" Name="t_fymc" VisibleIndex="1">
                    <PropertiesTextEdit Native="true" Width="200px" Style-Font-Size="10pt" MaxLength="20">
                        <ValidationSettings CausesValidation="true">
                            <RequiredField IsRequired="true" ErrorText="费用名称不可为空！"></RequiredField>
                        </ValidationSettings>
                        <Style Font-Size="10pt"></Style>
                    </PropertiesTextEdit>
                    <EditFormSettings CaptionLocation="Near" />
                    <EditFormSettings CaptionLocation="Near"></EditFormSettings>
                    <CellStyle HorizontalAlign="Center">
                    </CellStyle>
                </dx:GridViewDataTextColumn>
                <dx:GridViewDataComboBoxColumn Caption="费用类型" FieldName="fylx" Name="t_fylx" VisibleIndex="2">
                    <PropertiesComboBox Spacing="0" ValueType="System.String" Width="200px" Style-Font-Size="10pt">
                        <Items>
                            <dx:ListEditItem Text="固定费用" Value="G" />
                            <dx:ListEditItem Text="临时费用" Value="L" />
                            <dx:ListEditItem Text="按销售总金额浮动扣率" Value="X" />
                            <dx:ListEditItem Text="按付款方式销售金额浮动扣率" Value="F" />
                        </Items>
                        <Style Font-Size="10pt"></Style>
                    </PropertiesComboBox>
                </dx:GridViewDataComboBoxColumn>
                <dx:GridViewDataSpinEditColumn Caption="费用金额" FieldName="fyje" Name="t_fyje" VisibleIndex="3">
                    <PropertiesSpinEdit DisplayFormatString="g" Spacing="0" Width="200px">
                        <ValidationSettings CausesValidation="True">
                        </ValidationSettings>
                        <Style Font-Size="10pt">
                            
                        </Style>
                    </PropertiesSpinEdit>
                    <EditFormSettings CaptionLocation="Near" />
                    <CellStyle HorizontalAlign="Center">
                    </CellStyle>
                </dx:GridViewDataSpinEditColumn>
                <dx:GridViewDataComboBoxColumn Caption="付款方式" FieldName="fkfs" VisibleIndex="4" Name="t_fkfs">
                    <PropertiesComboBox Spacing="0" ValueType="System.String" Width="200px" Style-Font-Size="10pt">
                        <Style Font-Size="10pt"></Style>
                    </PropertiesComboBox>
                </dx:GridViewDataComboBoxColumn>
                <dx:GridViewDataSpinEditColumn Caption="扣率" FieldName="kl" Name="t_kl" VisibleIndex="5">
                    <PropertiesSpinEdit DisplayFormatString="p" NumberFormat="Custom" Spacing="0" Width="200px">
                        <ValidationSettings CausesValidation="True">
                        </ValidationSettings>
                        <Style Font-Size="10pt">
                            
                        </Style>
                    </PropertiesSpinEdit>
                    <EditFormSettings CaptionLocation="Near" />
                    <CellStyle HorizontalAlign="Center">
                    </CellStyle>
                </dx:GridViewDataSpinEditColumn>
                <dx:GridViewDataMemoColumn Caption="备注" FieldName="bz" Name="t_bz" VisibleIndex="6"
                    Visible="false">
                    <EditFormSettings CaptionLocation="Near" ColumnSpan="3" Visible="True" />
                    <PropertiesMemoEdit Width="550px" Height="50px" Style-Font-Size="10pt">
                        <Style Font-Size="10pt"></Style>
                    </PropertiesMemoEdit>
                    <EditFormSettings CaptionLocation="Near" ColumnSpan="3" Visible="True" />
                </dx:GridViewDataMemoColumn>
            </Columns>
            <Templates>
                <DetailRow>
                    <table width="100%">
                        <tr>
                            <td align="right">
                                创建人：
                            </td>
                            <td>
                                <dx:ASPxLabel ID="ASPxLabel19" runat="server" Text='<%# Eval("founder") %>'>
                                </dx:ASPxLabel>
                            </td>
                            <td align="right">
                                创建时间：
                            </td>
                            <td>
                                <dx:ASPxLabel ID="ASPxLabel20" runat="server" Text='<%# Eval("fdate") %>'>
                                </dx:ASPxLabel>
                            </td>
                        </tr>
                        <tr>
                            <td align="right">
                                最后修改人：
                            </td>
                            <td>
                                <dx:ASPxLabel ID="ASPxLabel21" runat="server" Text='<%# Eval("editor") %>'>
                                </dx:ASPxLabel>
                            </td>
                            <td align="right">
                                修改时间：
                            </td>
                            <td>
                                <dx:ASPxLabel ID="ASPxLabel22" runat="server" Text='<%# Eval("edate") %>'>
                                </dx:ASPxLabel>
                            </td>
                        </tr>
                        <tr>
                            <td align="right">
                                备注：
                            </td>
                            <td colspan="3">
                                <dx:ASPxLabel ID="ASPxLabel23" runat="server" Text='<%# Eval("bz") %>'>
                                </dx:ASPxLabel>
                            </td>
                        </tr>
                    </table>
                </DetailRow>
            </Templates>
            <Settings ShowFilterRow="True" />
            <SettingsDetail ShowDetailRow="True" />
            <SettingsEditing Mode="PopupEditForm" PopupEditFormHorizontalAlign="WindowCenter"
                PopupEditFormVerticalAlign="WindowCenter" PopupEditFormModal="True"></SettingsEditing>
            <Settings ShowFilterRow="True"></Settings>
            <SettingsDetail ShowDetailRow="True"></SettingsDetail>
            <Images SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css">
                <LoadingPanelOnStatusBar Url="~/App_Themes/Office2010Blue/GridView/Loading.gif">
                </LoadingPanelOnStatusBar>
                <LoadingPanel Url="~/App_Themes/Office2010Blue/GridView/Loading.gif">
                </LoadingPanel>
            </Images>
            <ImagesFilterControl>
                <LoadingPanel Url="~/App_Themes/Office2010Blue/GridView/Loading.gif">
                </LoadingPanel>
            </ImagesFilterControl>
            <Styles CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" CssPostfix="Office2010Blue">
                <Header ImageSpacing="5px" SortingImageSpacing="5px">
                </Header>
                <LoadingPanel ImageSpacing="5px">
                </LoadingPanel>
            </Styles>
            <StylesPager>
                <PageNumber ForeColor="#3E4846">
                </PageNumber>
                <Summary ForeColor="#1E395B">
                </Summary>
            </StylesPager>
            <StylesEditors ButtonEditCellSpacing="0">
                <ProgressBar Height="21px">
                </ProgressBar>
            </StylesEditors>
        </dx:ASPxGridView>
        <dx:LinqServerModeDataSource ID="LSMDSourceMain" runat="server" ContextTypeName="DAL.DataClassesDataContext"
            EnableDelete="True" EnableInsert="True" EnableUpdate="True" OnInserting="LSMDSourceMain_Inserting"
            OnUpdating="LSMDSourceMain_Updating" TableName="css_fee" />
    </div>
</asp:Content>
